package com.hyper_yang.javase.supplement.tryEnum.enumNow;

public enum Gender {
    MAN("男"),WOMAN("女");

    private String gender;

    // 构造器默认私有
    Gender(String gender) {
        this.gender = gender;
    }

    // 没重写输出 MAN 重写输出 gender属性值
    @Override
    public String toString() {
        return "'" + gender + "'";
    }
}
